<?php
/**
 * Created by PhpStorm.
 * User: Administrator
 * Date: 2017/10/12
 * Time: 10:04
 */
namespace app\common\model;
use think\Model;
class Shop extends Model{
    function add($data=[]){
        if(!is_array($data)) {
            exception('传递的数据不是数组');
        }

        
        return $this->data($data)->allowField(true)
            ->save();
    }
}